/**
 * 
 */
package test;


import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.SpriteSheetInterface;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.UniqueSpriteSheet;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.SpriteSheetCache;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.key.AbstractSheetKey;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.key.AvatarFrameKey;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.key.MotionFrameKey;
import it.unical.canonaco.rende.igpe.game.cbv.guilayer.sprites.key.PawnSheetKey;

import java.util.HashMap;

//import org.json.JSONException;
//import org.json.JSONObject;



/**
 * @author Massimo Canonaco
 *
 */
public class MassimoDialog {


	public static void main(String[] args) throws Throwable
	{
		
		SpriteSheetCache ssc = new SpriteSheetCache("testFolder", new HashMap<AbstractSheetKey,SpriteSheetInterface>());
		PawnSheetKey psk = new PawnSheetKey();
		psk.setWho("healer");
		psk.setWhat(PawnSheetKey.FRAME_TYPE_AVATAR);
		
		psk.setWhen("");
		
		AvatarFrameKey afk = new AvatarFrameKey();
		afk.setKey(AvatarFrameKey.MINI_AVATAR);
		psk.setFrameKey(afk);
		
		ssc.getImage(psk, 0, true);
		System.out.println("Una presa");
		ssc.getImage(psk, 0, true);
		psk.setWhat(PawnSheetKey.FRAME_TYPE_ANIMATIONS);
		psk.setWhen("hisback");
		
		MotionFrameKey mfk = new MotionFrameKey();
		mfk.setKey(MotionFrameKey.DEATH+"0");
		psk.setFrameKey(mfk);
		
		ssc.getImage(psk, 0, true);
		System.out.println("fine");
		
	}
}
